<?php

namespace App\ServicesNew;

use App\Entities\ProductSkuEntity;
use App\Meta\OrderPeriodDate;

/**
 * 库存服务
 * Interface StockService
 * @package App\ServicesNew
 */
interface StockService
{
    /**
     * @param int $cityId
     * @param int $productId
     * @return OrderPeriodDate
     */
    public function getLastServiceAbleDateTime(int $cityId, int $productId);

    /**
     * @param ProductSkuEntity $productSkuEntity
     * @return OrderPeriodDate
     */
    public function getLastServiceAbleDateTimeByProductSkuEntity(ProductSkuEntity $productSkuEntity);

    /**
     * 获取可选时间段
     * @param string $date
     * @param int $cityId
     * @param int $productId
     * @return array
     */
    public function getTimePeriodArr(string $date, int $cityId, int $productId);
}
